﻿<Window x:Class="STOCK.FNCBOOK"
        xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
        xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
        Title="FNCBOOK" Height="700" Width="900" Loaded="Window_Loaded" ResizeMode="NoResize">
    <Grid>
        <DockPanel>
            <Menu DockPanel.Dock="Top" Height="30">
                <MenuItem Header="文件">
                    <MenuItem Header="新建"></MenuItem>
                    <MenuItem Header="保存"></MenuItem>
                </MenuItem>
                
            </Menu>
            <Grid DockPanel.Dock="Top">
                <Grid.ColumnDefinitions>
                    <ColumnDefinition></ColumnDefinition>
                    <ColumnDefinition></ColumnDefinition>
                    <ColumnDefinition></ColumnDefinition>
                    <ColumnDefinition></ColumnDefinition>
                </Grid.ColumnDefinitions>
                <Grid.RowDefinitions>
                    <RowDefinition Height="210*"></RowDefinition>
                    <RowDefinition Height="179*"></RowDefinition>
                    <RowDefinition Height="242*"></RowDefinition>
                </Grid.RowDefinitions>

                <ListBox Height="209" SelectedValuePath="Id" DisplayMemberPath="Name" HorizontalAlignment="Center"  Name="lbCat" VerticalAlignment="Bottom" Width="88" SelectionChanged="lbCat_SelectionChanged" Margin="6,0,125,145" Grid.RowSpan="2" />
                <ListBox Height="340" SelectedValuePath="Id" DisplayMemberPath="Fun" HorizontalAlignment="Center" Name="lbFun" VerticalAlignment="Bottom" Width="162" Grid.RowSpan="2" SelectionChanged="lbFun_SelectionChanged" Grid.ColumnSpan="2" Margin="94,0,183,14" MouseDoubleClick="lbFun_MouseDoubleClick" />
                <TextBox TextWrapping="Wrap" Grid.Column="2" Height="503" HorizontalAlignment="Center"  Name="txtFNCContent" VerticalAlignment="Bottom" Width="430" Grid.ColumnSpan="2" Grid.RowSpan="3" AcceptsReturn="True" AcceptsTab="True" Margin="2,0,6,6" />
                <TextBox TextWrapping="Wrap" Grid.Row="2" Height="207" HorizontalAlignment="Left"  Name="txtDiscription" VerticalAlignment="Top" Width="422" Grid.ColumnSpan="2" Margin="17,29,0,0" AcceptsReturn="False" IsReadOnly="True" />
                <TextBlock Height="23" HorizontalAlignment="Left" Margin="17,6,0,0" Name="textBlock1" Text="函数分类" VerticalAlignment="Top" />
                <TextBlock Grid.Row="2" Height="23" HorizontalAlignment="Left" Margin="17,0,0,0" Name="textBlock2" Text="函数描述" VerticalAlignment="Top" />
                <TextBlock Grid.Column="1" Height="23" HorizontalAlignment="Left" Margin="36,6,0,0" Name="textBlock3" Text="函数名称" VerticalAlignment="Top" />
                <TextBlock Grid.Column="2" Height="23" HorizontalAlignment="Left" Margin="24,93,0,0" Name="textBlock4" Text="公式编写框" VerticalAlignment="Top" />
                <Button Content="清除" Grid.Column="2" Height="23" HorizontalAlignment="Left" Margin="116,89,0,0" Name="btnDelete" VerticalAlignment="Top" Width="75" Click="btnDelete_Click" />
                <Button Content="保存" Grid.Column="2" Height="23" HorizontalAlignment="Left" Margin="116,0,0,144" Name="btnSave" VerticalAlignment="Bottom" Width="75" Click="btnSave_Click" />
                <Button Content="打开" Grid.Column="2" Height="23" HorizontalAlignment="Left" Margin="24,44,0,0" Name="btnOpen" VerticalAlignment="Top" Width="75" Click="btnOpen_Click" />
                <TextBox  Grid.Column="2" Height="23" HorizontalAlignment="Left" Margin="100,6,0,0" Name="txtSaveRoot" VerticalAlignment="Top" Width="333" Grid.ColumnSpan="2" />
                <TextBox Grid.Column="3" Height="23" HorizontalAlignment="Left" Margin="93,45,0,0" Name="txtFNCName" VerticalAlignment="Top" Width="120" />
                <TextBlock Grid.Column="2" Height="23" HorizontalAlignment="Left" Margin="24,6,0,0" Name="textBlock6" Text="文件路径" VerticalAlignment="Top" />
                <TextBlock Grid.Column="3" Height="23" HorizontalAlignment="Left" Margin="21,45,0,0" Name="textBlock7" Text="公式名称" VerticalAlignment="Top" />
                <ListBox Grid.Column="1" SelectedValuePath="Id" DisplayMemberPath="Name" Height="340" HorizontalAlignment="Left" Margin="36,35,0,0" Name="lbFunName" VerticalAlignment="Top" Width="168" Grid.RowSpan="2" MouseDoubleClick="lbFunName_MouseDoubleClick" SelectionChanged="lbFunName_SelectionChanged" />
                <CheckBox Content="换行" Grid.Column="3" Height="16" HorizontalAlignment="Left" Margin="28,93,0,0" Name="cbEnter" VerticalAlignment="Top" />
                <CheckBox Content="：=" Grid.Column="3" Height="16" HorizontalAlignment="Left" Margin="132,93,0,0" Name="cbEq" VerticalAlignment="Top" />
            </Grid>
        </DockPanel>
        
    </Grid>
</Window>
